package sdk.weinxin.beans.massmessage;

import com.fasterxml.jackson.annotation.JsonProperty;
import java.util.Set;
import sdk.weinxin.beans.massmessage.preview.Preview;

/**
 * 高级群发接口数据
 *
 * @author LiYi
 *
 */
public abstract class MassMessage {

    @JsonProperty("msgtype")
    private String msgType;
    // 用于特定组
    private Filter filter;
    @JsonProperty("touser")
    // 用于指定用户
    private Set<String> toUser;
    // 开发者侧群发msgid，长度限制64字节，如不填，则后台默认以群发范围和群发内容的摘要值做为clientmsgid
    @JsonProperty("clientmsgid")
    private String clientMsgId; 

    /**
     * 转换为预览对象
     *
     * @return Preview 子对象
     */
    public abstract Preview convert();

    public String getMsgType() {
        return msgType;
    }

    public void setMsgType(String msgType) {
        this.msgType = msgType;
    }

    public Filter getFilter() {
        return filter;
    }

    public void setFilter(Filter filter) {
        this.filter = filter;
    }

    public Set<String> getToUser() {
        return toUser;
    }

    public void setToUser(Set<String> toUser) {
        this.toUser = toUser;
    }

    public String getClientMsgId() {
        return clientMsgId;
    }

    public void setClientMsgId(String clientMsgId) {
        this.clientMsgId = clientMsgId;
    }


}
